package com.zoro.jianyue.presenter.impl;

import android.content.Context;

import com.zoro.jianyue.interactor.HomeInteractor;
import com.zoro.jianyue.interactor.impl.HomeInteractorImpl;
import com.zoro.jianyue.view.HomeView;
import com.zoro.jianyue.presenter.Presenter;

/**
 * Created by CM-ZR on 2016/1/19.
 */
public class HomePresenterImpl implements Presenter {
    private Context mContext;
    private HomeView mHomeView;
    private HomeInteractor mHomeInteractor = null;

    public HomePresenterImpl(Context context, HomeView homeView) {
        if (null == homeView) {
            throw new IllegalArgumentException("Constructor's parameters must not be Null");
        }
        this.mContext = context;
        this.mHomeView = homeView;
        mHomeInteractor = new HomeInteractorImpl();
    }

    @Override
    public void initialized() {
        mHomeView.initalizeViews(mHomeInteractor.getPagerFragments(), mHomeInteractor.getNavigationListData(mContext));
    }
}
